<!--%import("../../tpl/js/signup_check.js")-->
<!--%import("filter/signup.xml")-->

<!--// datepicker javascript plugin load -->
<!--%load_js_plugin("ui")-->
<!--%load_js_plugin("ui.datepicker")-->

<!--#include("./common_header.html")-->

    <h3>{$lang->cmd_signup}</h3>

    <form id="fo_insert_member" action="./" method="get" onsubmit="return procFilter(this, signup)">

    <!--@if(!$is_logged && $member_config->agreement)-->
    <div class="agreementBox">
        {$member_config->agreement}
    </div>
    <div class="agreementButton">
        <input type="checkbox" name="accept_agreement" value="Y" id="accept_agree" />
        <label for="accept_agree">{$lang->about_accept_agreement}</label>
    </div>
    <!--@end-->

    <table cellspacing="0" class="rowTable">
    <tr>
        <th colspan="2" class="title"><div>{$lang->member_default_info}</div></th>
    </tr>
    <tr>
        <th><div>{$lang->user_id} <span class="require">*</span></div></th>
        <td class="wide"><input type="text" name="user_id" value="" class="iText"/> <p>{$lang->about_user_id}</p> </td>
    </tr>
    <tr>
        <th><div>{$lang->password} <span class="require">*</span></div></th>
        <td><input type="password" name="password1" value="" class="iText"/><p>{$lang->about_password}</p></td>
    </tr>
    <tr>
        <th><div>{$lang->password2} <span class="require">*</span></div></th>
        <td><input type="password" name="password2" value="" class="iText"/></td>
    </tr>
    <tr>
        <th><div>{$lang->user_name} <span class="require">*</span></div></th>
        <td>
            <input type="text" name="user_name" value="" class="iText"/><p>{$lang->about_user_name}</p>
        </td>
    </tr>
    <tr>
        <th><div>{$lang->nick_name} <span class="require">*</span></div></th>
        <td>
            <input type="text" name="nick_name" value="" class="iText"/><p>{$lang->about_nick_name}</p>
        </td>
    </tr>
    <tr>
        <th><div>{$lang->email_address} <span class="require">*</span></div></th>
        <td>
            <input type="text" name="email_address" value="" class="iText"/><p>{$lang->about_email_address}</p>
        </td>
    </tr>
	<!--@if(count($lang->find_account_question_items)>1)-->
    <tr>
        <th><div>{$lang->find_account_question} <span class="require">*</span></div></th>
        <td>
			<select name="find_account_question">
			<!--@for($i=1,$c=count($lang->find_account_question_items);$i<$c;$i++)-->
				<option value="{$i}">{$lang->find_account_question_items[$i]}</option>
			<!--@end-->
			</select>
            <br />
			<input type="text" name="find_account_answer" value="" class="iText w300"/>
        </td>
    </tr>
	<!--@end-->
    <tr>
        <th><div>{$lang->homepage}</div></th>
        <td>
            <input type="text" name="homepage" value="" class="iText"/><p>{$lang->about_homepage}</p>
        </td>
    </tr>
    <tr>
        <th><div>{$lang->blog}</div></th>
        <td>
            <input type="text" name="blog" value="" class="iText"/><p>{$lang->about_blog_url}</p>
        </td>
    </tr>
    <tr>
        <th><div>{$lang->birthday}</div></th>
        <td>
            <input type="hidden" name="birthday" id="date_birthday" value="" />
            <input type="text" value="" readonly="readonly" class="inputDate iText" />
			<span class="button"><input type="button" value="{$lang->cmd_delete}" class="dateRemover" /></span>
			<p>{$lang->about_birthday}</p>
        </td>
    </tr>
    <tr>
        <th><div>{$lang->allow_mailing}</div></th>
        <td><input type="checkbox" class="checkbox" name="allow_mailing" value="Y" checked="checked" /> <p>{$lang->about_allow_mailing}</p></td>
    </tr>
    <!--@if($extend_form_list)-->
    <tr>
        <th class="title" colspan="2"><div>{$lang->member_extend_info}</div></th>
    </tr>

        <!--@foreach($extend_form_list as $key => $val)--><!--@if($val->is_active=='Y')-->
        <tr>
            <th>
                {htmlspecialchars($val->column_title)}
                <!--@if($val->required=='Y')--><span class="require">*</span><!--@end-->
            </th>
        <td>
            <!--// 일반 text -->
            <!--@if($val->column_type == 'text')-->
                <input type="text" name="{$val->column_name}" value="{htmlspecialchars($val->value)}" class="iText w400" />

            <!--// 홈페이지 주소 -->
            <!--@elseif($val->column_type == 'homepage')-->
                <input type="text" name="{$val->column_name}" value="{htmlspecialchars($val->value)}" class="iText w400" />

            <!--// Email 주소 -->
            <!--@elseif($val->column_type == 'email_address')-->
                <input type="text" name="{$val->column_name}" value="{htmlspecialchars($val->value)}" class="iText w400" />

            <!--// 전화번호 -->
            <!--@elseif($val->column_type == 'tel')-->
                <input type="text" name="{$val->column_name}" value="{htmlspecialchars($val->value[0])}" size="4" class="iText" />
                <input type="text" name="{$val->column_name}" value="{htmlspecialchars($val->value[1])}" size="4" class="iText" />
                <input type="text" name="{$val->column_name}" value="{htmlspecialchars($val->value[2])}" size="4" class="iText" />

            <!--// textarea -->
            <!--@elseif($val->column_type == 'textarea')-->
                <textarea name="{$val->column_name}" class="iTextArea w400">{htmlspecialchars($val->value)}</textarea>

            <!--// 다중 선택 -->
            <!--@elseif($val->column_type == 'checkbox')-->
                <!--@if($val->default_value)-->
                    <ul class="checkbox">
                    <!--@foreach($val->default_value as $v)-->
                        <li><input type="checkbox" name="{$val->column_name}" value="{$v}" <!--@if(is_array($val->value)&&in_array($v, $val->value))-->checked="checked"<!--@end-->/>{$v}</li>
                    <!--@end-->
                    </ul>
                <!--@end-->


            <!--@elseif($val->column_type == 'radio')-->
                <!--@if($val->default_value)-->
                    <ul class="radio">
                    <!--@foreach($val->default_value as $v)-->
                        <li><input type="radio" name="{$val->column_name}" value="{$v}" <!--@if(is_array($val->value)&&in_array($v, $val->value))-->checked="checked"<!--@end-->/>{$v}</li>
                    <!--@end-->
                    </ul>
                <!--@end-->

            <!--// 단일 선택 -->
            <!--@elseif($val->column_type == 'select')-->
                <select name="{$val->column_name}">
                <!--@if($val->default_value)-->
                    <!--@foreach($val->default_value as $v)-->
                        <option value="{$v}" <!--@if($v == $val->value)-->selected="selected"<!--@end-->>{$v}</option>
                    <!--@end-->
                <!--@end-->
                </select>

            <!--// 한국 주소 검색 -->
            <!--@elseif($val->column_type == 'kr_zip')-->
                <div class="krZip">
                    <div class="item" id="zone_address_search_{$val->column_name}" style="display:none"|cond="$val->value[0]">
						<label for="krzip_address1_{$val->column_name}" class="iLabel">{$lang->msg_kr_address}</label>
                        <input type="text" id="krzip_address1_{$val->column_name}" class="iText w200" value="" />
                        <span class="button"><button type="button">{$lang->cmd_search}</button></span>
                    </div>
                    <div class="item" id="zone_address_list_{$val->column_name}" style="display:none">
                        <select name="{$val->column_name}" id="address_list_{$val->column_name}" class="w300"></select>
                        <span class="button"><button type="button">{$lang->cmd_search_again}</button></span>
                    </div>
                    <div class="item address2">
						<label for="krzip_address2_{$val->column_name}" class="iLabel">{$lang->msg_kr_address_etc}</label>
                        <input type="text" name="{$val->column_name}" id="krzip_address2_{$val->column_name}" value="{htmlspecialchars($val->value[1])}" class="iText w300" />
                    </div>
                </div>
				<load target="../../tpl/js/krzip_search.js" type="body" />
				<script type="text/javascript">jQuery(function($){ $.krzip('{$val->column_name}') });</script>
            <!--// 일본 주소 검색 -->
            <!--@elseif($val->column_type == 'jp_zip')-->
                <input type="text" name="{$val->column_name}" value="{htmlspecialchars($val->value)}" />

            <!--// 날짜 입력 -->
            <!--@elseif($val->column_type == 'date')-->
                <input type="hidden" name="{$val->column_name}" id="date_{$val->column_name}" value="{$val->value}" />
                <input type="text" class="inputDate iText" value="{zdate($val->value,'Y-m-d')}" readonly="readonly" />
				<span class="button"><input type="button" value="{$lang->cmd_delete}" class="dateRemover" /></span>
            <!--@end-->

            <p>{$val->description}</p>

            <div class="publicItem">
                <input type="checkbox" class="checkbox" name="open_{$val->column_name}" value="Y" id="open_{$val->column_name}" />
                <label for="open_{$val->column_name}">{$lang->public}</label>
            </div>
        </td>
    </tr>
        <!--@end--><!--@end-->
    <!--@end-->
    <tr>
        <th class="button" colspan="2">
            <span class="button black strong"><input type="submit" value="{$lang->cmd_registration}" accesskey="s" /></span>
            <a href="{getUrl('act','','member_srl','')}" class="button"><span>{$lang->cmd_cancel}</span></a>
        </th>
    </tr>
    </table>
</form>

<script type="text/javascript">
(function($){
    $(function(){
        var option = { changeMonth: true, changeYear: true, gotoCurrent: false,yearRange:'-100:+10', onSelect:function(){

            $(this).prev('input[type="hidden"]').val(this.value.replace(/-/g,""))}
        };
        $.extend(option,$.datepicker.regional['{$lang_type}']);
        $(".inputDate").datepicker(option);
		$(".dateRemover").click(function() {
			$(this).parent().prevAll('input').val('');
			return false;});
    });
})(jQuery);
</script>
<!--#include("./common_footer.html")-->
